import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import axios from 'axios'
Vue.prototype.$http = axios

import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';

Vue.use(ElementUI);

axios.defaults.baseURL = 'https://www.liulongbin.top:8888/api/private/v1'
axios.default.timeout = 5000
import ZkTable from 'vue-table-with-tree-grid'
Vue.component(ZkTable.name, ZkTable)
axios.interceptors.request.use(config => {
	// console.log(config)
	// 在最后必须  return config
	config.headers.Authorization = window.sessionStorage.getItem('token')
	return config
})
Vue.config.productionTip = false

new Vue({
	router,
	store,
	render: h => h(App)
}).$mount('#app')
